# http://www.linuxplanet.com/linuxplanet/tutorials/6750/2/

import pygtk
pygtk.require('2.0')
import gtk

class Board(gtk.DrawingArea):
	
	def __init__(self):
		gtk.DrawingArea.__init__(self)
		self.set_size_request(400,300)
		self.add_events(gtk.gdk.BUTTON_PRESS)
		
	
def event_handler(widget, event):
	w, h = widget.window.get_size()
	xgc = widget.window.new_gc()
	xgc.set_rgb_fg_color(gtk.gdk.color_parse("red"))
	widget.window.draw_line(xgc, 0, 0, w, h)
	

